Skip to content

enhance(cli, md): Allow custom background for inline code#430

Merged
JeanMertz merged 13 commits intomainfrom
prr6
Mar 11, 2026
Merged

enhance(cli, md): Allow custom background for inline code#430
JeanMertz merged 13 commits intomainfrom
prr6

Conversation

@JeanMertz
Copy link
Collaborator

Support configuring a custom background color for inline code spans via the style.inline_code.background setting. This allows users to improve the legibility of inline code when the theme's default background is too subtle or clashes with the terminal's palette.

The jp_md formatter now accepts an optional hex color that, when provided, overrides the theme-derived background for inline code.

In jp_cli, this configuration is passed from the global style config to the markdown renderer during query and conversation print.

Example configuration in config.toml:

[style.inline_code]
background = "#3c3836"

Support configuring a custom background color for inline code spans via
the `style.inline_code.background` setting. This allows users to improve
the legibility of inline code when the theme's default background is too
subtle or clashes with the terminal's palette.

The `jp_md` formatter now accepts an optional hex color that, when
provided, overrides the theme-derived background for inline code.

In `jp_cli`, this configuration is passed from the global style config
to the markdown renderer during `query` and `conversation print`.

Example configuration in `config.toml`:

```toml
[style.inline_code]
background = "#3c3836"
```

Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
@JeanMertz JeanMertz merged commit 2e41832 into main Mar 11, 2026
12 checks passed
@JeanMertz JeanMertz deleted the prr6 branch March 11, 2026 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant